const formatTime =date=>{
	const year = date.getFullYear()
	const month=date.getMonth() +1
	const day =date.getDate()
	const hour =date.getHours()
	const minute =date.getMinutes()
	const second =date.getSeconds()
	return year + "-" + month + "-" + day +"" +hour +":" +minute +":" +second
}


function remove(arr,pos){
	arr[pos] = arr[arr,length -1]
	arr.pop()
}
function checkLength(field,len,name){
	if(field.length>=len){
		return true
	}
	let message = name+"不能少于" +len +"个字符"
	if(field.length==0){
		message = name+"不能为空"
	}
	uni.showToast({
		title: message,
		icon:"none"
	});
	return false
}
module.exports = {
	formatTime,
	remove,
	checkLength
}